//
//  ContactInformation.m
//  UI_17_homework_Preview_NSFileManage
//
//  Created by li cheng on 16/8/6.
//  Copyright © 2016年 li cheng. All rights reserved.
//

#import "ContactInformation.h"

@implementation ContactInformation
- (instancetype)initWithCoder:(NSCoder *)aDecoder{
    self = [super init];
    if (self) {
        // 取值,反归档
        _imageName = [aDecoder decodeObjectForKey:@"imageName"];
        _name = [aDecoder decodeObjectForKey:@"name"];
        _contactWay = [aDecoder decodeObjectForKey:@"contactWay"];
        _address = [aDecoder decodeObjectForKey:@"address"];
    }
    return self;
}
// 赋值,归档
- (void)encodeWithCoder:(NSCoder *)aCoder{
    [aCoder encodeObject:_imageName forKey:@"imageName"];
    [aCoder encodeObject:_name forKey:@"name"];
    [aCoder encodeObject:_contactWay forKey:@"contactWay"];
    [aCoder encodeObject:_address forKey:@"address"];
}

@end
